<<<<<<< .mine
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package net.awpspace.caromini;

/**
 *
 * @author phamk_000
 */
public class BoardCaro {
    public int[][] board;
    public static int COL = 20;
    public static int ROW = 20;
    
    private static BoardCaro instance;
    public static BoardCaro getInstance(){
        if(instance == null)
            instance = new BoardCaro();
        return instance;
    }
    protected BoardCaro(){
        board = new int[ROW][COL];
        for(int i = 0; i < ROW; i++)
            for(int j = 0; j < COL; j++)
                board[i][j] = 0;
    }
    
    public int getValue(int x, int y){
        return board[x][y];
    }
    
    public void setValue(int x, int y, int value){
        board[x][y] = value;
//        System.out.println("\n===========================");
//        for(int i = 0; i < ROW; i ++){
//            for(int j = 0; j < COL; j++)
//                System.out.print(board[i][j]);
//            System.out.println();
//        }
    }
    public void reset(){
        for(int i = 0; i < ROW; i ++)
            for(int j = 0; j < COL; j++)
                board[i][j] = 0;
    }
}
=======
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package net.awpspace.caromini;

/**
 *
 * @author phamk_000
 */
public class BoardCaro {
    public int[][] board;
    public static int COL = 20;
    public static int ROW = 20;
    
    private static BoardCaro instance;
    public static BoardCaro getInstance(){
        if(instance == null)
            instance = new BoardCaro();
        return instance;
    }
    protected BoardCaro(){
        board = new int[ROW][COL];
        for(int i = 0; i < ROW; i++)
            for(int j = 0; j < COL; j++)
                board[i][j] = 0;
    }
    
    public int getValue(int x, int y){
        return board[x][y];
    }
    
    public void setValue(int x, int y, int value){
        board[x][y] = value;
        System.out.println("\n===========================");
        for(int i = 0; i < ROW; i ++){
            for(int j = 0; j < COL; j++)
                System.out.print(board[i][j]);
            System.out.println();
        }
    }
    public void reset(){
        for(int i = 0; i < ROW; i ++)
            for(int j = 0; j < COL; j++)
                board[i][j] = 0;
    }
}
>>>>>>> .r11
